<template>
    <example :template-code="templateString">
        <template #describe>
            <t :id="`${$t('普通按钮')}`">{{ $t('普通按钮') }}</t>
            <li>现象：点击多少次就会触发多少次事件</li>
        </template>
        <el-button type="primary" @click="handleClick">连续点击我</el-button>
    </example>
</template>

<script>
import { ElMessage } from 'element-plus';

export default {
    setup() {
        return {
            handleClick() {
                ElMessage.info('继续，不要停！');
            },
            templateString: `<template>
    <div class="example-box">
        <el-button type="primary" @click="handleClick">连续点击我</el-button>
    </div>
</template>

<script>
import { ElMessage } from 'element-plus';

export default {
    setup() {
        return {
            handleClick() {
                ElMessage.info('继续，不要停！');
            },
        };
    },
};
<\/script>`,
        };
    },
};
</script>
